<script setup>
import Header from "./Header.vue";
import Main from "./Main.vue";
import Footer from "./Footer.vue";
import Aside from "./Aside.vue";
const user = localStorage.getItem("user");
</script>
<template>
  <div>
    <div class="common-layout" v-if="user == 1">
      <el-container>
        <el-header style="padding: 0 0">
          <Header />
        </el-header>
        <el-container>
          <el-aside width="200px" v-if="user == 1">
            <Aside />
          </el-aside>
          <el-main>
            <Main />
          </el-main>
        </el-container>
      </el-container>
    </div>
    <div class="common-layout1" v-else>
      <el-container>
        <el-header style="padding: 0 0">
          <Header />
        </el-header>
        <el-container>
          <el-aside width="200px" v-if="user == 1">
            <Aside />
          </el-aside>
          <el-main>
            <Main />
          </el-main>
        </el-container>
      </el-container>
    </div>
  </div>
</template>
<style scoped>
.common-layout {
  height: 100vh;
  overflow: hidden;
}
.common-layout1 {
  height: 100vh;
}
</style>
